package com.erik.lin.controller;

import com.erik.lin.annotion.AuthCheck;
import com.erik.lin.service.ApiPermitService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.ResponseBody;

/**
 * Created by Erik on 2017/4/12.
 */
@Controller
@RequestMapping("/apiPermit")
public class ApiPermitController {

    @Autowired
    private ApiPermitService apiPermitService;

    @AuthCheck
    @RequestMapping(value = "/search/all", method = RequestMethod.GET)
    public @ResponseBody
    Object getAllPermitsRelaApi() {
        return apiPermitService.getAllPermitsRelaApi();
    }
}
